<include file="Public/head_top"/>
<body>
    <input type="hidden" name="deleteURL" id="SCURL" value="__URL__/removeSchoolInfo">
    <div class="content">
       <form action="__URL__/index" method="get">
        <div class="search">
            <div class="match-box">
               <div class="match-item">
                    <span>用户身份：</span>
                    <select name="teacher_type" size="1">
                        <option selected="selected" value="3" ></option>
                        <option  value="0" >普通用户</option>
                        <option  value="1">教师</option>
                         
                    </select>
                </div>    
                <div class="search-box">
                    <input type="text" name="nickname" value="" placeholder = "输入您要编辑的用姓名" >
                    <input type="submit" value=" ">
                </div>
            </div>
           
        </div>
    </form>
        <div class="biaoge">
            <div class="btn-box">
                <a href="__URL__/editor" class="btn-no-modal btn-add">新增用户</a>
            </div>
            <table>
                <tr>
                    <th width="20%">姓名</th>
                    <th width="10%">性别</th> 
                    <th width="10%">QQ号</th> 
                    <th width="10%">用户身份</th> 
                    <th width="10%">状态</th> 

                    <th width="50%"> 管理</th>
                </tr>
                <volist name="user" id="vo">
                     
                <tr>
                 

                    <td>{$vo.nickname}</td>
                    <td><if condition="$vo['sex'] eq 1 ">男    <else /> 女</if></td>
                    <td>{$vo.qq}</td>
                    <td><if condition="$vo['teacher_type'] eq 1 ">老师    <else /> 普通用户</if></td>
                    <td><if condition="$vo['status'] eq 1 ">正常    <else /> 禁止</if></td>
                     
                    <td> 
                        <a href="__URL__/editor/uid/{$vo.uid}" class=" img-btn" title="修改用户" style="line-height: 32px">修改</a>
                        
                        <a href="###" class=" img-btn btn-sc" title="删除用户" data_id="{$vo.uid}"style="line-height: 32px">删除</a>
                    </td>
               
                </tr>
                 </eq>
                </volist>
            </table>
                 
            <div class="m-page"> <a href="__URL__/school_search/p/1">首页</a>

                {$page}
             
                <span class="page-jump">
                    <form action="__URL__/school_search" >
                    <input name="p" type="text">
                    <input type="submit" value="GO">
                    </form>
                </span>
            </div>
        </div>
    </div>
<script>
    $(function() {
        $(".btn-sc").click(function() {
            var url = $("#SCURL").val();
            var uid = $(this).attr('data_id');

            var $this = $(this);
            $.post(url, {
                "uid": uid
            }, function(data) {
                $this.closest('tr').remove();
            });
        });
    });
    </script>

</body>
</html>